
var GD = {};

GD.DocumentPreviewer = function() {

    function previewDocument(url, title) {
        var properties = {
            width: $(window).width() * 0.75,
            height: $(window).height() * 0.75,
            location: '0',
            copyhistory: '0'
        };
        var specs = [];
        $.each(properties, function(k, v) {
            specs.push(k + '=' + v);
        });
        var newWindow = window.open(url, title, specs.join(','));
        if (window.focus) {newWindow.focus()}
    }

    return {
        previewDocument: previewDocument
    }
}


